STEP 2: Nice! We can see the grades in the console. Let's create a function to print each grade at a time.

  • Go to and drag Define Function with Parameter into the HELPER FUNCTION section.
  • Change the name of the function to print_grades and change the parameter to list_of_grades.
  • Drag Docstring into print_grades. Edit it to say """ Prints grades to the console """
  • Drag Function Call with Parameter into main. Change it to print_grades(grades).

To navigate the page using the TAB key, first press ESC to exit the code editor.

# THIS ACTIVITY IS IN PREVIEW ONLY MODE
  • Run Code
  • Submit Work
  • Next Activity
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)